-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve error messages #1134
base: master
Are you sure you want to change the base?
Improve error messages #1134
Conversation
Deployed to Cloudflare Pages
|
92d764e
to
cca9d7d
Compare
cca9d7d
to
2504455
Compare
@@ -152,6 +152,8 @@ | |||
"value": "{{value, number}}" | |||
}, | |||
"errors": { | |||
"canNotLoadData": "Can not load data", | |||
"canNotReachDataSource": "We were unable to reach the data source to request this data. This is probably a temporary (network?) problem. Please try again later.", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Friendly reminder: this is waiting for input from @donouwens
data: 'not found', | ||
headers: {}, | ||
}) | ||
return undefined |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Future API will probably return 404 comparable to: https://nexus.oasis.io/v1/emerald/transactions/61c977e15629c030e05d831beaf228c374c7f1bc0dacf032a2c3c428afebf8b1
// TODO: look for other error codes, too. | ||
// (Currently we are not aware of anything else) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Others: https://github.com/axios/axios/blob/6d4c421/README.md#error-types
ETIMEDOUT, ECONNABORTED, ERR_BAD_RESPONSE would indicate backend issue
Always try to properly differentiate between: - Illegal request (wrong address etc) - Failure to load data - Data not found
2504455
to
fe7fce9
Compare
Always try to properly differentiate between: